import request from "@/utils/request"

// 查询待办列表
export function getList(query) {
	return request({
		url: "/todo/config/list",
		method: "get",
		params: query
	})
}

// 获取待办任务配置详细信息
export function viewDetail(id) {
	return request({
		url: `/todo/config/${id}`,
		method: "get"
	})
}

// 新增待办
export function addItem(data) {
	return request({
		url: "/todo/config",
		method: "post",
		data
	})
}

// 修改待办
export function updateItem(data) {
	return request({
		url: "/todo/config",
		method: "put",
		data
	})
}

// 删除待办
export function delItems(ids) {
	return request({
		url: `/todo/config/${ids}`,
		method: "delete"
	})
}
